<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.18"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>NINJA: NINJA/DistanceCalculator.hpp Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">NINJA
   &#160;<span id="projectnumber">2.x</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.18 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('_distance_calculator_8hpp_source.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">DistanceCalculator.hpp</div>  </div>
</div><!--header-->
<div class="contents">
<a href="_distance_calculator_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="preprocessor">#ifndef DISTANCECALCULATOR_HPP</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="preprocessor">#define DISTANCECALCULATOR_HPP</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160; </div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="_exception_handler_8hpp.html">ExceptionHandler.hpp</a>&quot;</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160; </div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="preprocessor">#include &lt;cmath&gt;</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#include &lt;cfloat&gt;</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor">#include &lt;xmmintrin.h&gt;</span>        <span class="comment">/* SSE  */</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor">#include &lt;emmintrin.h&gt;</span>        <span class="comment">/* SSE2 */</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor">#include &lt;tmmintrin.h&gt;</span>      <span class="comment">/* SSE3 */</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor">#include &lt;cstdint&gt;</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160; </div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160; </div>
<div class="line"><a name="l00014"></a><span class="lineno"><a class="line" href="class_distance_calculator.html">   14</a></span>&#160;<span class="keyword">class </span><a class="code" href="class_distance_calculator.html">DistanceCalculator</a> {</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;    <span class="keyword">const</span> <span class="keywordtype">float</span> bl45[21][21];</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="keyword">public</span>:</div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160; </div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160; </div>
<div class="line"><a name="l00019"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609">   19</a></span>&#160;    <span class="keyword">enum</span> <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609">CorrectionType</a> {</div>
<div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a5f3b3cb6619f0d29daf2ff29a772d93c">   20</a></span>&#160;        <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a5f3b3cb6619f0d29daf2ff29a772d93c">not_assigned</a>, <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a4f1b606366478e0f0f4c8acd4de71583">none</a>, <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609aeb17fea69ad9aef888f2419a2814abf9">JukesCantor</a><span class="comment">/*DNA*/</span>, <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a08d9cb898efb2c44ad9fd7b09d6c7e50">Kimura2</a><span class="comment">/*DNA*/</span>, <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a82d5f2ef688449e3584c82448b739b88">FastTree</a> <span class="comment">/*amino*/</span>};</div>
<div class="line"><a name="l00021"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7c">   21</a></span>&#160;    <span class="keyword">enum</span> <a class="code" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7c">AlphabetType</a> {</div>
<div class="line"><a name="l00022"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7cafb040d095728a3f8116779a3cd63b2af">   22</a></span>&#160;        <a class="code" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7cafb040d095728a3f8116779a3cd63b2af">dna</a>, <a class="code" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7cad0f2f6fb9391cbe99f3f7b9dc4cfd63a">amino</a>, <span class="keyword">null</span></div>
<div class="line"><a name="l00023"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7ca36b2c09e572187e6f03fa8bde6fda574">   23</a></span>&#160;    };</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160; </div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;    <a class="code" href="class_distance_calculator.html#a2a8861e559827f4a9324b854edc13e58">DistanceCalculator</a>(std::string **<a class="code" href="class_distance_calculator.html#a00bdfa4cc790ce19056cf06894e205f4">A</a> <span class="comment">/*alignment*/</span>, <a class="code" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7c">AlphabetType</a> alphType, <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609">CorrectionType</a> corrType,</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;                       <span class="keywordtype">int</span> <a class="code" href="class_distance_calculator.html#a0a797aedff55422df2d8dc526d397bcb">numberOfSequences</a>, <span class="keywordtype">bool</span> useSSE);</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160; </div>
<div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;    <a class="code" href="class_distance_calculator.html#a937924271f1403a83408b4807589bd91">~DistanceCalculator</a>();</div>
<div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160; </div>
<div class="line"><a name="l00030"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a7d15fa02f8da2455998c97b3c18d0bc0">   30</a></span>&#160;    <a class="code" href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7c">AlphabetType</a> <a class="code" href="class_distance_calculator.html#a7d15fa02f8da2455998c97b3c18d0bc0">alph_type</a>;</div>
<div class="line"><a name="l00031"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a546dee19652efa8267f27b4baead4dfb">   31</a></span>&#160;    <a class="code" href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609">CorrectionType</a> <a class="code" href="class_distance_calculator.html#a546dee19652efa8267f27b4baead4dfb">corr_type</a>;</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160; </div>
<div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a1f57ec0ac50ea709a7a8c349167d6199">   33</a></span>&#160;    std::string <a class="code" href="class_distance_calculator.html#a1f57ec0ac50ea709a7a8c349167d6199">dna_chars</a>;</div>
<div class="line"><a name="l00034"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a721cb1b004a4d856515be5b8c4fc0fc4">   34</a></span>&#160;    std::string <a class="code" href="class_distance_calculator.html#a721cb1b004a4d856515be5b8c4fc0fc4">aa_chars</a>;</div>
<div class="line"><a name="l00035"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a00bdfa4cc790ce19056cf06894e205f4">   35</a></span>&#160;    std::string **<a class="code" href="class_distance_calculator.html#a00bdfa4cc790ce19056cf06894e205f4">A</a>;</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160; </div>
<div class="line"><a name="l00037"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a0a797aedff55422df2d8dc526d397bcb">   37</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_distance_calculator.html#a0a797aedff55422df2d8dc526d397bcb">numberOfSequences</a>;</div>
<div class="line"><a name="l00038"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a42ec2af34a954839847fca06288c1aca">   38</a></span>&#160;    <span class="keywordtype">int</span> <a class="code" href="class_distance_calculator.html#a42ec2af34a954839847fca06288c1aca">lengthOfSequences</a>;</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160; </div>
<div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;    <span class="comment">//TODO: set this as true only if it has support for SSE3</span></div>
<div class="line"><a name="l00041"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#aab6b17cfa53aa960ed4fcfadfb160408">   41</a></span>&#160;    <span class="keywordtype">bool</span> <a class="code" href="class_distance_calculator.html#aab6b17cfa53aa960ed4fcfadfb160408">newCalculation</a>;</div>
<div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160; </div>
<div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160; </div>
<div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;    <span class="keywordtype">double</span> <a class="code" href="class_distance_calculator.html#a3103ea39f1b1dbdbb7e23afd2adbd959">calc</a>(<span class="keywordtype">int</span> a, <span class="keywordtype">int</span> b);</div>
<div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160; </div>
<div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">int</span> *<a class="code" href="class_distance_calculator.html#a852203aaa2f7eb7faf53cc52245244f1">getInverseAlphabet</a>(std::string alph, <span class="keywordtype">int</span> length);</div>
<div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160; </div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;    <span class="keywordtype">double</span> <a class="code" href="class_distance_calculator.html#ac315efce21a47f3e77fb61ea933f930b">testDifferenceCluster</a>(<span class="keywordtype">int</span> a, <span class="keywordtype">int</span> b);</div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160; </div>
<div class="line"><a name="l00050"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a99279654c09ff392eed4cf5b03051158">   50</a></span>&#160;    <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> **<a class="code" href="class_distance_calculator.html#a99279654c09ff392eed4cf5b03051158">convertedSequences</a>;</div>
<div class="line"><a name="l00051"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#ae6a08d5f607d2fab97983f956dcee6eb">   51</a></span>&#160;    <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> **<a class="code" href="class_distance_calculator.html#ae6a08d5f607d2fab97983f956dcee6eb">gapInTheSequences</a>;</div>
<div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160; </div>
<div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160; </div>
<div class="line"><a name="l00054"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a61a73417e46e0c2b9a4d5d95a6ed4d81">   54</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a61a73417e46e0c2b9a4d5d95a6ed4d81">x128</a>;</div>
<div class="line"><a name="l00055"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#aa6b5621fcd3799f2b7e5840c75015c25">   55</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#aa6b5621fcd3799f2b7e5840c75015c25">zero</a>;</div>
<div class="line"><a name="l00056"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a432c5d8e0379f014219ce28eb81945d5">   56</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a432c5d8e0379f014219ce28eb81945d5">GAPS_COUNT_MASK</a>;</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160; </div>
<div class="line"><a name="l00058"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a9f70a25047b64665cb1ac392482df94f">   58</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a9f70a25047b64665cb1ac392482df94f">DECOMPRESSED_GAPS</a>;</div>
<div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#ab530628f3fb6f7e216ef6d378665e66a">   59</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#ab530628f3fb6f7e216ef6d378665e66a">COUNTS_MASK</a>;</div>
<div class="line"><a name="l00060"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a47d1216e0b5d0cbc662a7c151d283329">   60</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a47d1216e0b5d0cbc662a7c151d283329">TRANSITIONS_MASK</a>;</div>
<div class="line"><a name="l00061"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#ab1a3b734787d672be007ec68c1b48cd7">   61</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#ab1a3b734787d672be007ec68c1b48cd7">TRANSVERSIONS_MASK</a>;</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160; </div>
<div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a68fa9153f40a2a4b67afb724eb8264aa">   63</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a68fa9153f40a2a4b67afb724eb8264aa">VALUES_0</a>;</div>
<div class="line"><a name="l00064"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a6935cc06e8a5fbd492f39dae5363d7be">   64</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a6935cc06e8a5fbd492f39dae5363d7be">VALUES_1</a>;</div>
<div class="line"><a name="l00065"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a1c75c34fd473c9b06536add609dc9904">   65</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a1c75c34fd473c9b06536add609dc9904">VALUES_2</a>;</div>
<div class="line"><a name="l00066"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#adcc6485001fef7a3e41224859103753e">   66</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#adcc6485001fef7a3e41224859103753e">VALUES_3</a>;</div>
<div class="line"><a name="l00067"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a2d1c775e20f24225a31b05548b6b8e43">   67</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a2d1c775e20f24225a31b05548b6b8e43">VALUES_4</a>;</div>
<div class="line"><a name="l00068"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a2bd93b7a5642f21d26ba73a866d4b025">   68</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a2bd93b7a5642f21d26ba73a866d4b025">VALUES_5</a>;</div>
<div class="line"><a name="l00069"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#a86d7a9392e657a3712692d81a616b413">   69</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#a86d7a9392e657a3712692d81a616b413">VALUES_6</a>;</div>
<div class="line"><a name="l00070"></a><span class="lineno"><a class="line" href="class_distance_calculator.html#afbbc9af71772eb396f61bf24639c42f0">   70</a></span>&#160;    __m128i <a class="code" href="class_distance_calculator.html#afbbc9af71772eb396f61bf24639c42f0">VALUES_7</a>;</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160; </div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160; </div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;<span class="keyword">private</span>:</div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;    <span class="keywordtype">int</span> *inv_alph;</div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160; </div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;    <span class="keywordtype">int</span> protein_dict[256];</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;    <span class="keywordtype">int</span> protein_dict_original[256];</div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;    <span class="keywordtype">int</span> additionalGaps; <span class="comment">//inverse of the number of gaps added at the end of the sequence in sse calculation</span></div>
<div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160; </div>
<div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;    <span class="keyword">inline</span> <span class="keywordtype">void</span> count128(<span class="keyword">register</span> __m128i &amp;seq1, <span class="keyword">register</span> __m128i &amp;seq2, <span class="keyword">register</span> __m128i &amp;gap1, <span class="keyword">register</span> __m128i &amp;gap2,</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;                         <span class="keyword">register</span> __m128i &amp;tmp, <span class="keyword">register</span> __m128i &amp;tmp2, <span class="keyword">register</span> __m128i &amp;tmp3,</div>
<div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;                         <span class="keyword">register</span> __m128i &amp;count_transversions, <span class="keyword">register</span> __m128i &amp;count_transitions,</div>
<div class="line"><a name="l00083"></a><span class="lineno">   83</span>&#160;                         <span class="keyword">register</span> __m128i &amp;count_gaps) <span class="keyword">const</span>;</div>
<div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160; </div>
<div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;    <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span></div>
<div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;    count128P(<span class="keyword">register</span> __m128i &amp;seq1, <span class="keyword">register</span> __m128i &amp;seq2, <span class="keyword">register</span> __m128i &amp;gap1, <span class="keyword">register</span> __m128i &amp;gap2,</div>
<div class="line"><a name="l00087"></a><span class="lineno">   87</span>&#160;              <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a68fa9153f40a2a4b67afb724eb8264aa">VALUES_0</a>, <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a6935cc06e8a5fbd492f39dae5363d7be">VALUES_1</a>, <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a1c75c34fd473c9b06536add609dc9904">VALUES_2</a>,</div>
<div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160;              <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#adcc6485001fef7a3e41224859103753e">VALUES_3</a>, <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a2d1c775e20f24225a31b05548b6b8e43">VALUES_4</a>, <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a2bd93b7a5642f21d26ba73a866d4b025">VALUES_5</a>,</div>
<div class="line"><a name="l00089"></a><span class="lineno">   89</span>&#160;              <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#a86d7a9392e657a3712692d81a616b413">VALUES_6</a>, <span class="keyword">register</span> __m128i &amp;<a class="code" href="class_distance_calculator.html#afbbc9af71772eb396f61bf24639c42f0">VALUES_7</a>, <span class="keyword">register</span> __m128i &amp;sum,</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;              <span class="keyword">register</span> __m128i &amp;gap_count, <span class="keyword">register</span> __m128i &amp;tmp1, <span class="keyword">register</span> __m128i &amp;tmp2, <span class="keywordtype">int</span> a, <span class="keywordtype">int</span> b);</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160; </div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;    <span class="keywordtype">double</span> newCalcDNA(<span class="keywordtype">int</span> a, <span class="keywordtype">int</span> b);</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160; </div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;    <span class="keywordtype">double</span> newCalcProtein(<span class="keywordtype">int</span> a, <span class="keywordtype">int</span> b);</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160; </div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;    <span class="keywordtype">void</span> convertAllDNA();</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160; </div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;    <span class="keywordtype">void</span> convertAllProtein();</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160; </div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> getBitsDNA(<span class="keyword">const</span> <span class="keywordtype">char</span> *seq, <span class="keywordtype">int</span> *size, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> *seqOut, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> *gapOut);</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160; </div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> generateProteinClusterDict(<span class="keywordtype">int</span> *protein_dictionary);</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160; </div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;    <span class="keywordtype">void</span> getBitsProteinClustered(<span class="keyword">const</span> <span class="keywordtype">char</span> *seq, <span class="keywordtype">int</span> *size, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> *seqOut, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> *gapOut);</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160; </div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> generateProteinOriginalDict(<span class="keywordtype">int</span> *protein_dictionary);</div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160; </div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;    <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> *getProteinDic(std::string alph, <span class="keywordtype">int</span> length);</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160; </div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;};</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160; </div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;<span class="preprocessor">#endif</span></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<div class="ttc" id="aclass_distance_calculator_html_a937924271f1403a83408b4807589bd91"><div class="ttname"><a href="class_distance_calculator.html#a937924271f1403a83408b4807589bd91">DistanceCalculator::~DistanceCalculator</a></div><div class="ttdeci">~DistanceCalculator()</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.cpp:900</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a1c75c34fd473c9b06536add609dc9904"><div class="ttname"><a href="class_distance_calculator.html#a1c75c34fd473c9b06536add609dc9904">DistanceCalculator::VALUES_2</a></div><div class="ttdeci">__m128i VALUES_2</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:65</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609a5f3b3cb6619f0d29daf2ff29a772d93c"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a5f3b3cb6619f0d29daf2ff29a772d93c">DistanceCalculator::not_assigned</a></div><div class="ttdeci">@ not_assigned</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:20</div></div>
<div class="ttc" id="aclass_distance_calculator_html_aba37861b27b2e9a8e12b0aea4fcb5c7cad0f2f6fb9391cbe99f3f7b9dc4cfd63a"><div class="ttname"><a href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7cad0f2f6fb9391cbe99f3f7b9dc4cfd63a">DistanceCalculator::amino</a></div><div class="ttdeci">@ amino</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:22</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609a82d5f2ef688449e3584c82448b739b88"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a82d5f2ef688449e3584c82448b739b88">DistanceCalculator::FastTree</a></div><div class="ttdeci">@ FastTree</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:20</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a42ec2af34a954839847fca06288c1aca"><div class="ttname"><a href="class_distance_calculator.html#a42ec2af34a954839847fca06288c1aca">DistanceCalculator::lengthOfSequences</a></div><div class="ttdeci">int lengthOfSequences</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:38</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a432c5d8e0379f014219ce28eb81945d5"><div class="ttname"><a href="class_distance_calculator.html#a432c5d8e0379f014219ce28eb81945d5">DistanceCalculator::GAPS_COUNT_MASK</a></div><div class="ttdeci">__m128i GAPS_COUNT_MASK</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:56</div></div>
<div class="ttc" id="a_exception_handler_8hpp_html"><div class="ttname"><a href="_exception_handler_8hpp.html">ExceptionHandler.hpp</a></div></div>
<div class="ttc" id="aclass_distance_calculator_html_a2bd93b7a5642f21d26ba73a866d4b025"><div class="ttname"><a href="class_distance_calculator.html#a2bd93b7a5642f21d26ba73a866d4b025">DistanceCalculator::VALUES_5</a></div><div class="ttdeci">__m128i VALUES_5</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:68</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a86d7a9392e657a3712692d81a616b413"><div class="ttname"><a href="class_distance_calculator.html#a86d7a9392e657a3712692d81a616b413">DistanceCalculator::VALUES_6</a></div><div class="ttdeci">__m128i VALUES_6</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:69</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a721cb1b004a4d856515be5b8c4fc0fc4"><div class="ttname"><a href="class_distance_calculator.html#a721cb1b004a4d856515be5b8c4fc0fc4">DistanceCalculator::aa_chars</a></div><div class="ttdeci">std::string aa_chars</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:34</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a7d15fa02f8da2455998c97b3c18d0bc0"><div class="ttname"><a href="class_distance_calculator.html#a7d15fa02f8da2455998c97b3c18d0bc0">DistanceCalculator::alph_type</a></div><div class="ttdeci">AlphabetType alph_type</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:30</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a68fa9153f40a2a4b67afb724eb8264aa"><div class="ttname"><a href="class_distance_calculator.html#a68fa9153f40a2a4b67afb724eb8264aa">DistanceCalculator::VALUES_0</a></div><div class="ttdeci">__m128i VALUES_0</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:63</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a9f70a25047b64665cb1ac392482df94f"><div class="ttname"><a href="class_distance_calculator.html#a9f70a25047b64665cb1ac392482df94f">DistanceCalculator::DECOMPRESSED_GAPS</a></div><div class="ttdeci">__m128i DECOMPRESSED_GAPS</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:58</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609aeb17fea69ad9aef888f2419a2814abf9"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609aeb17fea69ad9aef888f2419a2814abf9">DistanceCalculator::JukesCantor</a></div><div class="ttdeci">@ JukesCantor</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:20</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a2d1c775e20f24225a31b05548b6b8e43"><div class="ttname"><a href="class_distance_calculator.html#a2d1c775e20f24225a31b05548b6b8e43">DistanceCalculator::VALUES_4</a></div><div class="ttdeci">__m128i VALUES_4</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:67</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a546dee19652efa8267f27b4baead4dfb"><div class="ttname"><a href="class_distance_calculator.html#a546dee19652efa8267f27b4baead4dfb">DistanceCalculator::corr_type</a></div><div class="ttdeci">CorrectionType corr_type</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:31</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a61a73417e46e0c2b9a4d5d95a6ed4d81"><div class="ttname"><a href="class_distance_calculator.html#a61a73417e46e0c2b9a4d5d95a6ed4d81">DistanceCalculator::x128</a></div><div class="ttdeci">__m128i x128</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:54</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a1f57ec0ac50ea709a7a8c349167d6199"><div class="ttname"><a href="class_distance_calculator.html#a1f57ec0ac50ea709a7a8c349167d6199">DistanceCalculator::dna_chars</a></div><div class="ttdeci">std::string dna_chars</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:33</div></div>
<div class="ttc" id="aclass_distance_calculator_html_aba37861b27b2e9a8e12b0aea4fcb5c7c"><div class="ttname"><a href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7c">DistanceCalculator::AlphabetType</a></div><div class="ttdeci">AlphabetType</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:21</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a47d1216e0b5d0cbc662a7c151d283329"><div class="ttname"><a href="class_distance_calculator.html#a47d1216e0b5d0cbc662a7c151d283329">DistanceCalculator::TRANSITIONS_MASK</a></div><div class="ttdeci">__m128i TRANSITIONS_MASK</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:60</div></div>
<div class="ttc" id="aclass_distance_calculator_html_ab530628f3fb6f7e216ef6d378665e66a"><div class="ttname"><a href="class_distance_calculator.html#ab530628f3fb6f7e216ef6d378665e66a">DistanceCalculator::COUNTS_MASK</a></div><div class="ttdeci">__m128i COUNTS_MASK</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:59</div></div>
<div class="ttc" id="aclass_distance_calculator_html"><div class="ttname"><a href="class_distance_calculator.html">DistanceCalculator</a></div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:14</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a99279654c09ff392eed4cf5b03051158"><div class="ttname"><a href="class_distance_calculator.html#a99279654c09ff392eed4cf5b03051158">DistanceCalculator::convertedSequences</a></div><div class="ttdeci">unsigned int ** convertedSequences</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:50</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a00bdfa4cc790ce19056cf06894e205f4"><div class="ttname"><a href="class_distance_calculator.html#a00bdfa4cc790ce19056cf06894e205f4">DistanceCalculator::A</a></div><div class="ttdeci">std::string ** A</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:35</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a3103ea39f1b1dbdbb7e23afd2adbd959"><div class="ttname"><a href="class_distance_calculator.html#a3103ea39f1b1dbdbb7e23afd2adbd959">DistanceCalculator::calc</a></div><div class="ttdeci">double calc(int a, int b)</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.cpp:802</div></div>
<div class="ttc" id="aclass_distance_calculator_html_ac315efce21a47f3e77fb61ea933f930b"><div class="ttname"><a href="class_distance_calculator.html#ac315efce21a47f3e77fb61ea933f930b">DistanceCalculator::testDifferenceCluster</a></div><div class="ttdeci">double testDifferenceCluster(int a, int b)</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.cpp:705</div></div>
<div class="ttc" id="aclass_distance_calculator_html_ab1a3b734787d672be007ec68c1b48cd7"><div class="ttname"><a href="class_distance_calculator.html#ab1a3b734787d672be007ec68c1b48cd7">DistanceCalculator::TRANSVERSIONS_MASK</a></div><div class="ttdeci">__m128i TRANSVERSIONS_MASK</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:61</div></div>
<div class="ttc" id="aclass_distance_calculator_html_afbbc9af71772eb396f61bf24639c42f0"><div class="ttname"><a href="class_distance_calculator.html#afbbc9af71772eb396f61bf24639c42f0">DistanceCalculator::VALUES_7</a></div><div class="ttdeci">__m128i VALUES_7</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:70</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a0a797aedff55422df2d8dc526d397bcb"><div class="ttname"><a href="class_distance_calculator.html#a0a797aedff55422df2d8dc526d397bcb">DistanceCalculator::numberOfSequences</a></div><div class="ttdeci">int numberOfSequences</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:37</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609">DistanceCalculator::CorrectionType</a></div><div class="ttdeci">CorrectionType</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:19</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a852203aaa2f7eb7faf53cc52245244f1"><div class="ttname"><a href="class_distance_calculator.html#a852203aaa2f7eb7faf53cc52245244f1">DistanceCalculator::getInverseAlphabet</a></div><div class="ttdeci">static int * getInverseAlphabet(std::string alph, int length)</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.cpp:64</div></div>
<div class="ttc" id="aclass_distance_calculator_html_aba37861b27b2e9a8e12b0aea4fcb5c7cafb040d095728a3f8116779a3cd63b2af"><div class="ttname"><a href="class_distance_calculator.html#aba37861b27b2e9a8e12b0aea4fcb5c7cafb040d095728a3f8116779a3cd63b2af">DistanceCalculator::dna</a></div><div class="ttdeci">@ dna</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:22</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a2a8861e559827f4a9324b854edc13e58"><div class="ttname"><a href="class_distance_calculator.html#a2a8861e559827f4a9324b854edc13e58">DistanceCalculator::DistanceCalculator</a></div><div class="ttdeci">DistanceCalculator(std::string **A, AlphabetType alphType, CorrectionType corrType, int numberOfSequences, bool useSSE)</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.cpp:8</div></div>
<div class="ttc" id="aclass_distance_calculator_html_aab6b17cfa53aa960ed4fcfadfb160408"><div class="ttname"><a href="class_distance_calculator.html#aab6b17cfa53aa960ed4fcfadfb160408">DistanceCalculator::newCalculation</a></div><div class="ttdeci">bool newCalculation</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:41</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609a4f1b606366478e0f0f4c8acd4de71583"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a4f1b606366478e0f0f4c8acd4de71583">DistanceCalculator::none</a></div><div class="ttdeci">@ none</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:20</div></div>
<div class="ttc" id="aclass_distance_calculator_html_a6935cc06e8a5fbd492f39dae5363d7be"><div class="ttname"><a href="class_distance_calculator.html#a6935cc06e8a5fbd492f39dae5363d7be">DistanceCalculator::VALUES_1</a></div><div class="ttdeci">__m128i VALUES_1</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:64</div></div>
<div class="ttc" id="aclass_distance_calculator_html_affde42ac598a1597aba092e781de6609a08d9cb898efb2c44ad9fd7b09d6c7e50"><div class="ttname"><a href="class_distance_calculator.html#affde42ac598a1597aba092e781de6609a08d9cb898efb2c44ad9fd7b09d6c7e50">DistanceCalculator::Kimura2</a></div><div class="ttdeci">@ Kimura2</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:20</div></div>
<div class="ttc" id="aclass_distance_calculator_html_ae6a08d5f607d2fab97983f956dcee6eb"><div class="ttname"><a href="class_distance_calculator.html#ae6a08d5f607d2fab97983f956dcee6eb">DistanceCalculator::gapInTheSequences</a></div><div class="ttdeci">unsigned int ** gapInTheSequences</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:51</div></div>
<div class="ttc" id="aclass_distance_calculator_html_adcc6485001fef7a3e41224859103753e"><div class="ttname"><a href="class_distance_calculator.html#adcc6485001fef7a3e41224859103753e">DistanceCalculator::VALUES_3</a></div><div class="ttdeci">__m128i VALUES_3</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:66</div></div>
<div class="ttc" id="aclass_distance_calculator_html_aa6b5621fcd3799f2b7e5840c75015c25"><div class="ttname"><a href="class_distance_calculator.html#aa6b5621fcd3799f2b7e5840c75015c25">DistanceCalculator::zero</a></div><div class="ttdeci">__m128i zero</div><div class="ttdef"><b>Definition:</b> DistanceCalculator.hpp:55</div></div>
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_994258571ff4fe75827c48a736f217ad.html">NINJA</a></li><li class="navelem"><a class="el" href="_distance_calculator_8hpp.html">DistanceCalculator.hpp</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.18 </li>
  </ul>
</div>
</body>
</html>
